Ext.define('MyApp.store.FeedItemStore', {
    extend: 'Ext.data.Store',
    requires: [
        'MyApp.model.FeedItem'
    ],

    constructor: function(cfg) {
        var me = this;
        cfg = cfg || {};
        me.callParent([Ext.apply({
            storeId: 'FeedItemStore',
            model: 'MyApp.model.FeedItem',
            proxy: {
                type: 'ajax',
                url: 'feed-proxy.php',
                reader: {
                    type: 'xml',
                    record: 'item'
                }
            },
            sorters: {
                direction: 'DESC',
                property: 'pubDate'
            }
        }, cfg)]);
    }
});